 var id = getvl("id");
 $(function(){
	     if(id!=''){
	     	   goodsguanlis();
	     }else{
	     	alert("未传入有效值");
	     }
});
    
var pageNo=1;     
function goodsguanlis(){
	alert("...");
		$.ajax({
		url: urlcore + "/api/goods/Commoditymanagement?current="+pageNo+"&userId=15&types=2",
		type: "get",
		dataType: 'json',
		contentType: "application/json;charset=utf-8",
		success:function(data){
			if (data.success == true) {
			
				$.each(data.data.list, function(y,n) {
                    var goodsguanli='<div class="clearfix add_goods">'+
'		<div class="public-xuanze fl public-checkbox">'+
'			<label class="goodsCheck">'+
'            	<input type="checkbox" />'+
'            </label>'+
'		</div>'+
'		<div class="clearfix tuwen">'+
'	    	<a href="javascript:void(0);">'+
'		        <div class="tuwen-img fl">'+
'		            <img onerror="errorImg(this)" src="'+n.coverUrl+'" width="75" height="75">'+
'		        </div>'+
'		        <div class="tuwen-wenzi">'+
'		            <h5 class="wuye_h01">'+n.goodsTitle+'</h5>'+
'		            <div class="wuye_div02">&yen;'+n.tradePrice+'-&yen;'+n.getPrice+'</div>'+
'		        </div>'+
'	        </a>'+
'	    </div>'+
'	</div>';
                    $("#goodsguanli").append(goodsguanli);					
				});
            
                 			    
			}
		},
		error:function() {
			alert("error");
		}
	});
}
